package com.webflux.webflux02.dao;

import com.webflux.webflux02.entity.Product;
import org.springframework.data.r2dbc.repository.Query;
import org.springframework.data.repository.reactive.ReactiveCrudRepository;
import reactor.core.publisher.Flux;


public interface ProductRepository  extends ReactiveCrudRepository<Product,Integer> {

    @Query("select * from product where type=:type limit :page,:pageSize")
    Flux<Product> findByPage(String type,int page,int pageSize);

}
